package com.nineclock.api.system;

import com.nineclock.attendance.dto.DepartmentOrUserSimpleDTO;
import com.nineclock.common.entity.PageResult;
import com.nineclock.common.entity.Result;
import com.nineclock.system.dto.SysCompanyUserDTO;
import com.nineclock.system.dto.SysDepartmentDTO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.util.List;

@Api(value = "组织管理接口", tags = "系统服务")
public interface OrganizationControllerApi {
	
    @ApiOperation(value = "组织架构: 查询组织所有员工")
    public Result<List<SysCompanyUserDTO>> queryCompanyMemberList();

    @ApiOperation(value = "查询组织部门列表")
    public Result<List<SysDepartmentDTO>> queryDepartmentList();

    @ApiOperation(value = "分页查询部门下的员工数据列表")
    public Result<PageResult<SysCompanyUserDTO>> members(Integer page, Integer pageSize, String keyword, Long departmentId);

    @ApiOperation(value = "直接导入企业员工")
    public Result uploadExcel(MultipartFile excelFile) throws IOException;

    @ApiOperation("查询顶级部门的id")
    public Result<List<Long>> queryDepartmentIds();

    @ApiOperation("根据部门id查询子部门的人数")
    public Result<Integer> queryUserCountByDepartmentIds(List<Long> departmentIds);


    @ApiOperation(value = "根据部门ID查询子部门及员工列表")
    public Result<List<DepartmentOrUserSimpleDTO>> querySimpleDepartment(Long departmentId, Integer includeMember);

}